package com.hw.protocol.tool.decode.hw;

import com.hw.protocol.tool.model.entity.hw.AbsFlowMeter;
import com.hw.protocol.tool.model.entity.hw.Dtu61His;

/**
 * @author : lihy
 * @date : 2023/3/23 10:15
 * description: 流量计(6130/6131)历史数据解码器
 */

public class Dtu61HisDecode extends Dtu61Decode implements IHisDecode {

    private Dtu61His fm;

    public Dtu61HisDecode(AbsFlowMeter fm, byte[] data) {
        super(fm, data);
        this.fm = (Dtu61His)fm;
    }

    @Override
    protected void setTime() {
        fm.setTime(getTime(dataBuf));
    }

    @Override
    protected boolean hisData() {
        return true;
    }
}
